<!Doctype html>
<html>
<head>
    <meta charset="utf-8">
    <title>大旺福--{$title}</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">
    <link rel="stylesheet" href="/assets/layui/css/layui.css" media="all">
    <link rel="stylesheet" href="/assets/layui/css/global.css" media="all">
    <link rel="stylesheet" href="/assets/layui/css/admin.css" media="all">
    {literal}
    <style type="text/css">
    		.layui-body{left: 0;}
    		.save-content{text-align: right;}
    </style>
    {/literal}
</head>
<body>
    <div class="layui-layout">
        <!-- main start -->
        <div class="layui-body">
            <div class="layui-main">
                <fieldset class="layui-elem-field layui-field-title">
                    <legend>{$title}</legend>
                </fieldset>
                <div class="site-block">
                    
					<div class="searchbar">
						<form action="#" method="get" class="layui-form search-from">
							<input type="hidden" name="search_list" value='{$search_array_str}'/>
							 <div class="layui-form-item">
							    <div class="layui-input-inline">
									<select class="auto" name="search[shop_id]">
										<option value="">选择供应商</option>
										{foreach from=$shop item=one}
										<option value="{$one.id}">{$one.shop_name}</option>
										{/foreach}
									</select>							      
							    </div>
							    <!--
							    <div class="layui-input-inline">
									<select class="auto" name="search[shelf]">
										<option value="">选择上下架</option>
										<option value="1">上架</option>
										<option value="0">下架</option>
									</select>								      
							    </div>
							    <div class="layui-input-inline">
									<select class="auto" name="search[status]">
										<option value="">选择状态</option>
										<option value="1">待审核</option>
										<option value="2">审核通过</option>
										<option value="0">审核未通过</option>
									</select>								      
							    </div>
							    <div class="layui-input-inline">
									<select class="auto" name="search[store_nums]">
										<option value="">选择库存</option>
										<option value="0">无货</option>
										<option value="10">低于10</option>
										<option value="100">10-100</option>
										<option value="1000">100以上</option>
									</select>								      
							    </div>
							    -->
							    <div class="layui-input-inline">
									<select class="auto" name="search[name]">
										<option value="name" {if $search_array.name eq 'name'} selected{/if}>商品名</option>
										<option value="goods_no" {if $search_array.name eq 'goods_no'} selected{/if}>商品货号</option>
									</select>																	      
							    </div>
							    <div class="layui-input-inline">
							      <input type="text" name="search[keywords]"  autocomplete="off" class="layui-input" value="{$search_array.keywords}">
							    </div>
							    <div class="layui-input-inline button-warp">
							    		<input type="hidden" name="search[categroy_select_id]" value="">
							    		<button type="button" class="layui-btn layui-btn-warm layui-btn-small category-select" style="margin-top:5px;"><i class="layui-icon">&#xe608;</i> <span>选择分类</span></button>
							    </div>
							    <div class="layui-input-inline button-warp">
							    		<button type="button" class="layui-btn layui-btn-small search-button" style="margin-top:5px;"><i class="layui-icon">&#xe615;</i> <span>筛选</span></button>
							    </div>
							 </div>
							<!--<button class="btn" onclick="changeAction(true)"><span class="sel">导出Excel</span></button>-->
						</form>
					</div>
					<hr />
					<div class="content">
						<table class="list_table">
							<colgroup>
								<col width="40px">
								<col width="360px">
								<col width="180px">
								<col width="90px">
								<col width="70px">
								<col width="80px">
								<col width="70px">
								<col width="110px">
							</colgroup>
							<thead>
								<tr class="">
									<th>选择</th>
									<th>商品名称</th>
									<th>分类</th>
									<th>销售价</th>
									<th>库存</th>
									<th>状态</th>
									<th>排序</th>
								</tr>
							</thead>
					
							<tbody>
								{foreach from=$products item=product}
								<tr class="">
									<td><input name="id[]" type="checkbox" value="{$product.id}"></td>
									<td class="product-name">{$product.product_name}</td>
									<td>
										{foreach from=$product.category item=categoty}
										[{$categoty.category_name}]
										{/foreach}
									</td>
									<td>{$product.member_price}</td>
									<td>{$product.inventory}</td>
									<td>
										{if $product.shelf eq 1} 
										上架
										{else}
										下架
										{/if}
									</td>
									<td>{$product.f_order}</td>
								</tr>
								{/foreach}												
							</tbody>
						</table>
					</div> 
					<div class="pages_bar">
						{$pageStr}
						<span>当前第{$currentPage}页/共{$totalPage}页</span>
					</div>
					<div class="save-content">
						<button type="button" class="layui-btn layui-btn-big save-button" style="margin-top:5px;"><span>确定</span></button>
					</div>
                </div>

            </div>
        </div>
        <!-- main end -->

    </div>
	<div id="category-content" style="display: none;">
		<input type="hidden" name="categroy_id" value="0">
	    <button type="button" class="layui-btn layui-btn-warm layui-btn-small add-category layui-hide" style="margin-top:5px;"><i class="layui-icon">&#xe608;</i> <span>选择分类</span></button>
	    <div class="category-list layui-clear site-block" style="padding:10px;">
	        <ul id="category-tree" class="layui-box layui-tree" style="margin-bottom:10px;"></ul>
	    </div>
	</div>
    {include file="layout/footerJs.html"}
    <script src="/assets/layui/js/product/mini_product_list.js"></script>
</body>
</html>